package org.digital.common;

import lombok.Getter;

public class Modbus {
    @Getter
    public enum DATATYPE{
        BIT(1, 1, "bit"),
        SIGNED_INT16(2, 2, "(signed)Int16"),
        UNSIGNED_INT16(3, 2, "(unsigned)Int16"),
        BIG_SIGNED_INT32(4, 4, "(signed)Int32[AB-CD]"),
        LITTLE_SIGNED_INT32(5, 4, "(signed)Int32[CD-AB]"),
        BIG_UNSIGNED_INT32(6, 4, "(unsigned)Int32[AB-CD]"),
        LITTLE_UNSIGNED_INT32(7, 4, "(unsigned)Int32[CD-AB]"),
        BIG_FLOAT32(8, 4, "Float32[AB-CD]"),
        LITTLE_FLOAT32(9, 4, "Float32[CD-AB]"),
        BIG_FLOAT64(10, 8, "Float64[AB-CD]"),
        LITTLE_FLOAT64(11, 8, "Float64[CD-AB]");
        private final int length;
        private final int value;
        private final String node;

        DATATYPE(int value, int length, String node){
            this.value = value;
            this.length = length;
            this.node = node;
        }
    }




}
